﻿<%@ Control Language="C#" AutoEventWireup="true" CodeFile="CN.ascx.cs" Inherits="CN" %>
<center>
            <asp:Panel ID="pnGroupGrid" runat="server" Width="500px">
                <asp:DataGrid Width="100%" ID="datagrid" runat="server" AutoGenerateColumns="False"
            PageSize="20" OnItemCommand="datagrid_ItemCommand" OnItemDataBound="datagrid_ItemDataBound"
            AllowPaging="True" OnPageIndexChanged="datagrid_PageIndexChanged">
                    <PagerStyle Mode="NumericPages"></PagerStyle>
                    <AlternatingItemStyle CssClass="DarkRow"></AlternatingItemStyle>
                    <ItemStyle CssClass="LightRow"></ItemStyle>
                    <HeaderStyle Font-Bold="True" CssClass="HeaderRow"></HeaderStyle>
                    <Columns>
                        <asp:BoundColumn DataField="MaKho" HeaderText="Mã kho PGD">
                            <HeaderStyle CssClass="HeaderRow"></HeaderStyle>
                        </asp:BoundColumn>
                        <asp:BoundColumn DataField="TenKho" HeaderText="Tên PGD">
                            <ItemStyle HorizontalAlign="Left" />
                        </asp:BoundColumn>
                        <asp:TemplateColumn>
                            <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            <ItemTemplate>
                                <asp:Button CausesValidation="False" ID="cmdEdit" runat="server" Text="Sửa" Width="40"
                                    CommandName="cmdEdit"></asp:Button>
                            </ItemTemplate>
                        </asp:TemplateColumn>
                        <asp:TemplateColumn>
                            <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            <ItemTemplate>
                                <asp:Button CausesValidation="False" ID="cmdDelete" runat="server" Text="Xóa" Width="40"
                                    CommandName="cmdDelete"></asp:Button>
                            </ItemTemplate>
                        </asp:TemplateColumn>
                    </Columns>
                </asp:DataGrid>
                <asp:SqlDataSource ID="ds" runat="server" ConnectionString="<%$ ConnectionStrings:DBConnectionString %>"
                    ProviderName="<%$ ConnectionStrings:DBConnectionString.ProviderName %>"></asp:SqlDataSource>
                <asp:Button ID="cmdAddNew" runat="server" Text="Thêm mới" OnClick="cmdAddNew_Click">
                </asp:Button>
            </asp:Panel>
            <asp:Panel ID="pnEdit" runat="server" Width="500px">
                <table class="Area" style="border-right: gray 1px solid; border-top: gray 1px solid;
                    border-left: gray 1px solid; border-bottom: gray 1px solid" cellspacing="5" cellpadding="0"
                    width="500" border="0">
                    <tr>
                        <td style="color: blue" align="center" colspan="3">
                            <asp:Label ID="Label1" runat="server"></asp:Label></td>
                    </tr>
                    <tr>
                        <td width="10">
                        </td>
                        <td class="SubHead">
                            Mã kho PGD</td>
                        <td>
                            <asp:TextBox ID="txtMaKho" Width="200px" runat="server" Enabled="False"></asp:TextBox>
                            (Không được chứa ký tự đặc biệt.)</td>
                    </tr>
                    <tr>
                        <td width="10">
                        </td>
                        <td class="SubHead">
                            Tên kho PGD</td>
                        <td>
                            <asp:TextBox ID="txtTenKho" Width="200px" runat="server"></asp:TextBox></td>
                    </tr>
                    <tr>
                        <td style="color: red; font-family: arial" align="center" colspan="3" height="10">
                            <asp:Label ID="lblError" runat="server"></asp:Label><asp:Label ID="lblUpdateStatus" runat="server"></asp:Label></td>
                    </tr>
                    <tr>
                        <td align="center" colspan="3">
                            <asp:Button ID="cmdUpdate" Width="72px" Text="Cập nhật" runat="server" CausesValidation="true"
                                OnClick="cmdUpdate_Click"></asp:Button>
                            <asp:Button ID="cmdCancel" Width="72" Text="Quay lại" runat="server" CausesValidation="False"
                                OnClick="cmdCancel_Click"></asp:Button></td>
                    </tr>
                </table>
            </asp:Panel>
</center>